package cn.ffcs.bpmpvc.assignhandler;

import java.util.List;

import org.echoice.spring.SpringContextUtil;

import cn.ffcs.bpm.model.TransactProcessStatus;
import cn.ffcs.bpmpvc.services.AppBusinessReqService;
import cn.ffcs.bpmpvc.svc.TaskAssignHandler;
import cn.ffcs.organ.model.Organization;
import cn.ffcs.organ.model.Person;
/**
 * 发起人所在部门经理
 * @author Administrator
 *
 */
public class DeptCheckTaskAssignHandler implements TaskAssignHandler {

	public List<Person> executeAssign(TransactProcessStatus processStatus, Object context) {
		// TODO Auto-generated method stub		
		Organization organization=(Organization)context;		
		List list=null;
		if(context!=null){
			System.out.println(">>>>>>>>>>>>>>>>>>>>>>>.."+organization.getId());
			AppBusinessReqService appBusinessReqService=(AppBusinessReqService)SpringContextUtil.getBean("appBusinessReqService");
			//list=appBusinessReqService.getAppBusinessReqDao().findPersonByOrg(organization.getId(), "组长");
			list=appBusinessReqService.getAppBusinessReqDao().findPersonByOrg(organization.getId(), new String[]{"组长","副组长","主任","副主任"});
		}
		return list;
	}

}
